package com.lian.dao;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.jdbc.core.JdbcTemplate;
import org.springframework.stereotype.Repository;

import com.lian.domain.LoginLog;

@Repository
public class LoginLogDao {
	@Autowired
	private JdbcTemplate jdbc;
	
	public void insertLoginLog(LoginLog log){
		String sql = "INSERT INTO `t_login_log`(user_id,ip,login_datetime) VALUES(?,?,?)";
		jdbc.update(sql, log.getUserId(),log.getIp(),log.getLoginDate());
	}
	
	
}
